<!--
 * @Author: 追逐的娃 kangchao_php@163.com
 * @Date: 2024-07-02 10:53:07
 * @LastEditors: 追逐的娃 kangchao_php@163.com
 * @LastEditTime: 2024-07-02 18:12:34
 * @FilePath: \xiyufengqing\H5\src\views\PlaceAnOrder\List.vue
 * @Description: 
 * 
-->
<template>
  <div>
    <van-nav-bar :title="title" fixed left-arrow @click-left="onClickLeft" />
    <!-- 店面 -->
    <div class="store_info">
      <div class="left">
        <img src="@/assets/canting.png" alt="" />
      </div>
      <div class="right">
        <h2>西域风情</h2>
        <p class="desc">新疆菜宣传者</p>
      </div>
    </div>
    <div class="menus">
      <van-tabs v-model:active="active" sticky>
      <van-tab title="商品"> 内容 {{ index }} </van-tab>
    </van-tabs>
    </div>
  </div>
</template>

<script setup>
import { computed, ref } from 'vue'
import { useRoute } from 'vue-router'
import { useSystemStore } from '@/stores'

const system = useSystemStore()
const route = useRoute()
const currentDesk = ref([])
const title = ref('')
const active = ref('1')
//获取参数
const getQuery = () => {
  let object = route.query
  for (const key in object) {
    currentDesk.value.push(object[key])
    system.deskNumber.map((item) => {
      if (object[key] == item.id) {
        title.value += item.tableNo + '桌'
      }
    })
  }
  console.log(system.deskNumber)
}
getQuery()
//返回上一页
const onClickLeft = () => {}
</script>

<style lang="scss" scoped>
div.store_info {
  padding: 60px 20px;
  display: flex;
  div.left {
    width: 100px;
    margin-right: 10px;
    img {
      width: 100%;
      height: auto;
    }
  }

  div.right {
    h2 {
      font-size: 20px;
    }

    p.desc {
      font-size: 16px;
    }
  }
}
.menus{
  display: flex;
}
</style>
